package com.example.demo.model;

import lombok.Data;

import java.util.Date;

@Data
public class ChatMessage {
    private Integer id;
    private Integer senderId;
    private Integer receiverId;
    private String content;
    private Date createTime;
    private Integer status; // 0:未读 1:已读
    private Integer productId;  // 添加商品ID字段
    private String contentType; // 内容类型：TEXT/HTML
    
    // 扩展字段
    private String senderName;
    private String senderAvatar;
    private String productImage;
    private String productName;
    private Double productPrice;
    private Long fromUserId;  // 添加这个字段
    private Long toUserId;    // 如果没有这个字段也需要添加
    private String type;    // 添加消息类型字段
} 